****** Table_11_5:  Replications
* Because the data being merged in are cross-sections and contain all data needed to run them we will use the year 2000 as an arbitrary year for our regressions to avoid blowing up the N and falsely reducing the SE
use data/Demo_book_country_3.dta, clear

* Hariri
merge m:1 country_id using "data/hariri_9_7.dta", gen(_mergeHariri)
drop(_mergeHariri)

reg hariri_mean_polity2_91_07 hariri_statehiste1500_01n hariri_latitude hariri_africa hariri_asia hariri_lac hariri_meast2 hariri_lpd1500s if year == 2000, robust

reg hariri_mean_polity2_91_07 eur_pct_1991 hariri_statehiste1500_01n hariri_latitude hariri_africa hariri_asia hariri_lac hariri_meast2 hariri_lpd1500s if year == 2000, robust

* Woodberry
merge m:1 country_id using "data/woodberry_9_7.dta", gen(_mergeWoodberry)
drop(_mergeWoodberry)

rreg wby_Ldem5094 wby_Britcol wby_Nobrprot wby_Dutchcol wby_Nosigcol wby_Latitude wby_Island wby_Landlock wby_Euroback wby_PctMuslim1970 wby_Bigoil wby_Litb4mis wby_Yrsmis60 wby_Npmispc23x10k wby_Epct1900 wby_Yrcathmis1444_1960 wby_Cmis23oldpopx10k wby_Yr1stdem wby_Libornot if year == 2000
display e(r2)

rreg wby_Ldem5094 wby_Britcol wby_Nobrprot wby_Dutchcol wby_Nosigcol wby_Latitude wby_Island wby_Landlock wby_PctMuslim1970 wby_Bigoil wby_Litb4mis wby_Yrsmis60 wby_Npmispc23x10k wby_Epct1900 wby_Yrcathmis1444_1960 wby_Cmis23oldpopx10k wby_Yr1stdem wby_Libornot if year == 2000
display e(N)
display e(r2)

rreg wby_Ldem5094 wby_Britcol wby_Nobrprot wby_Dutchcol wby_Nosigcol wby_Latitude wby_Island wby_Landlock wby_PctMuslim1970 wby_Bigoil wby_Litb4mis eur_pct_1950 wby_Yrsmis60 wby_Npmispc23x10k wby_Epct1900 wby_Yrcathmis1444_1960 wby_Cmis23oldpopx10k wby_Yr1stdem wby_Libornot if year == 2000
display e(N)
display e(r2)

* Olsson
merge m:1 country_id using "data/olsson_9_7.dta", gen(_mergeOlsson)
drop(_mergeOlsson)

reg olss_pol2007 olss_duration olss_yrsindep olss_polindep olss_island olss_logarea olss_logmort olss_landlocked if year == 2000, robust

reg olss_pol2007 eur_pct_2007 olss_duration olss_yrsindep olss_polindep olss_island olss_logarea olss_logmort olss_landlocked if year == 2000, robust

* Drop the variables again to avoid confusion/problems
drop hariri_* wby_* olss_* eur_pct_1950 eur_pct_1991 eur_pct_2007
